//
//  AppDelegate.m
//  EPA
//
//  Created by lanou3g on 16/4/13.
//  Copyright © 2016年 liman. All rights reserved.
//

#import "AppDelegate.h"
#import "CK_MenuViewController.h"
#import "LMLoginController.h"
//导入ShareSDK头文件
#import <ShareSDK/ShareSDK.h>
#import <ShareSDKConnector/ShareSDKConnector.h>
//导入新浪微博的头文件
#import "WeiboSDK.h"
@interface AppDelegate ()

@end

@implementation AppDelegate


- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

//    sleep(10);等待10秒再开启
    [self.window makeKeyAndVisible];
[CK_MenuViewController  instanceWithLeftViewController:nil CenterViewController:self.window.rootViewController];

    
#pragma mark - 注册初始化shareSDK
    [ShareSDK registerApp:@"'" activePlatforms:@[@(SSDKPlatformTypeSinaWeibo)] onImport:^(SSDKPlatformType platformType) {
        switch (platformType) {
            case SSDKPlatformTypeSinaWeibo:
                [ShareSDKConnector connectWeibo:[WeiboSDK class]];
                break;
                
            default:
                break;
        }
    } onConfiguration:^(SSDKPlatformType platformType, NSMutableDictionary *appInfo) {
        switch (platformType) {
            case SSDKPlatformTypeSinaWeibo:
                //                App Key：3063489429
                //                App Secret：1fc1c73443770842f917e773c91b18de
                [appInfo SSDKSetupSinaWeiboByAppKey:@"3063489429" appSecret:@"1fc1c73443770842f917e773c91b18de" redirectUri:@"http://sns.whalecloud.com/sina2/callback" authType:SSDKAuthTypeBoth];
                break;
                
            default:
                break;
        }
    }];



    
    
    return YES;
}






















- (void)applicationWillResignActive:(UIApplication *)application {

}

- (void)applicationDidEnterBackground:(UIApplication *)application {

}

- (void)applicationWillEnterForeground:(UIApplication *)application {

}

- (void)applicationDidBecomeActive:(UIApplication *)application {

}

- (void)applicationWillTerminate:(UIApplication *)application {

}

@end
